home *** CD-ROM | disk | FTP | other *** search
/ NeXT Education Software Sampler 1992 Fall / NeXT Education Software Sampler 1992 Fall.iso / Programming / Source / nxyplot1.87 / defs.h < prev    next >
Encoding:
C/C++ Source or Header  |  1991-09-20  |  1.2 KB  |  47 lines

  1. /* collecting all the defines in one place */
  2.  
  3. #define ALLOCSIZE 2048        /* used in readData */
  4.  
  5. #define N_LINE_STYLES 6        /* number of line styles (including none) */
  6. #define N_SYMBOL_STYLES 8    /* number of symbol styles (including none) */
  7.  
  8. #ifndef MIN
  9. #define MIN(x,y) ((x)<(y)? (x) : (y))
  10. #endif
  11.  
  12. #ifndef MAX
  13. #define MAX(x,y) ((x)>(y)? (x) : (y))
  14. #endif
  15.  
  16. #ifndef ABS
  17. #define ABS(x) ( (x)<0? (-(x)) : (x) )
  18. #endif
  19.  
  20. #ifndef SGN
  21. #define SGN(x) ( (x)<0? -1.0 : 1.0 )
  22. #endif
  23.  
  24. #define XOFFSET 100.0        /* offsets (in pixels) of axis origin from */
  25. #define YOFFSET  50.0        /* lower left hand corner of window        */
  26.  
  27. #define SQRT3  1.73205081
  28.  
  29. enum movetypes {NOZOOM = 0, ZOOM = 1, MOVELEGEND = 2, MOVEXTITLE = 3,
  30.          MOVEYTITLE = 4, MOVEMAINTITLE = 5};
  31.  
  32. enum symboltypes {NOSYMBOL = 0, CIRCLE = 1, XMARK = 2, UPTRIANGLE = 3,
  33.             DOWNTRIANGLE = 4, DIAMOND = 5, SQUARE = 6, PLUS = 7};
  34.  
  35. enum linetypes {SOLID = 0, DASH = 1, DOT = 2, CHAINDASH = 3,
  36.           CHAINDOT = 4, NOLINE = 5};
  37.  
  38. #define DEFAULTFONTSIZE 12.0
  39.  
  40. #define DEFAULTAXISTITLEWIDTH 31.332
  41. /* The width of the default xtitle and ytitle in the default font
  42.  * (returned by [axisTitleFont getWidthOf:xtitle], e.g.)
  43.  */
  44.  
  45. #define DEFAULTMAINTITLEWIDTH 60.676
  46. /* 60.676 is the width of the default main title in the default font */
  47.